// Package member
// @Link  https://github.com/bufanyun/hotgo
// @Copyright  Copyright (c) 2023 HotGo CLI
// @Author  Ms <133814250@qq.com>
// @License  https://github.com/bufanyun/hotgo/blob/master/LICENSE
package v1

import (
	"github.com/gogf/gf/v2/frame/g"
	"hotgo/internal/model/input/apiin"
	"hotgo/internal/model/input/form"
)

// 获取权益列表
type IntegralBenefitsListReq struct {
	g.Meta `path:"/product/integralBenefits" method:"get" tags:"商品" summary:"获取积分权益列表"`
	apiin.IntegralBenefitsInp
}

type IntegralBenefitsListRes struct {
	form.PageRes
	List []*apiin.IntegralBenefitsModel `json:"list" dc:"数据列表"`
}

// 获取团购列表
type ProductGroupBuyReq struct {
	g.Meta `path:"/product/groupBuy" method:"get" tags:"商品" summary:"获取团购列表"`
	apiin.ProductGroupBuyInp
}

type ProductGroupBuyRes struct {
	form.PageRes
	List []*apiin.ProductGroupBuyModel `json:"list" dc:"数据列表"`
}

// 获取商品信息
type ProductInfoReq struct {
	g.Meta `path:"/product/info" method:"get" tags:"商品" summary:"获取商品信息"`
	apiin.ProductInfoInp
}

type ProductInfoRes struct {
	apiin.ProductInfoModel
}

// 获取门店信息
type StoreInfoReq struct {
	g.Meta `path:"/store/info" method:"get" tags:"商品" summary:"获取门店信息"`
	apiin.StoreInfoInp
}

type StoreInfoRes struct {
	Distance float64 `json:"distance"       dc:"距离(km)"`
	apiin.StoreInfoModel
}

// 获取门店团购列表
type StoreGroupBuyReq struct {
	g.Meta `path:"/store/groupBuy" method:"get" tags:"商品" summary:"获取门店团购列表"`
	apiin.StoreGroupBuyInp
}

type StoreGroupBuyRes struct {
	form.PageRes
	List []*apiin.StoreGroupBuyModel `json:"list" dc:"数据列表"`
}

// 搜索商品
type SearchProductReq struct {
	g.Meta `path:"/product/search" method:"get" tags:"商品" summary:"搜索商品"`
	apiin.SearchProductInp
}

type SearchProductRes struct {
	form.PageRes
	List []*apiin.SearchProductModel `json:"list" dc:"数据列表"`
}
